package cn.edu.zut.domain;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import org.springframework.stereotype.Component;

import java.io.Serializable;
import java.util.List;

@Component
@JsonIgnoreProperties(value = {"handler"})
public class User implements Serializable {
    private static final long serialVersionUID = 5402008423544687256L;
    private Integer _id;
    private String userName;
    private String passwd;
    private String nickName;
    private String gender;

    private Dep dep;
    private Status status;
    private List<ContestRegistry> contestRegistries;

    public User() {
    }

    @Override
    public String toString() {
        return "User{" +
                "_id=" + _id +
                ", userName='" + userName + '\'' +
                ", passwd='" + passwd + '\'' +
                ", nickName='" + nickName + '\'' +
                ", gender='" + gender + '\'' +
                ", dep=" + dep +
                ", status=" + status +
                ", contestRegistries=" + contestRegistries +
                '}';
    }


    public List<ContestRegistry> getContestRegistries() {
        return contestRegistries;
    }

    public void setContestRegistries(List<ContestRegistry> contestRegistries) {
        this.contestRegistries = contestRegistries;
    }

    public static long getSerialVersionUID() {
        return serialVersionUID;
    }

    public Integer get_id() {
        return _id;
    }

    public void set_id(Integer _id) {
        this._id = _id;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getPasswd() {
        return passwd;
    }

    public void setPasswd(String passwd) {
        this.passwd = passwd;
    }

    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickName) {
        this.nickName = nickName;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    public Dep getDep() {
        return dep;
    }

    public void setDep(Dep dep) {
        this.dep = dep;
    }

    public Status getStatus() {
        return status;
    }

    public void setStatus(Status status) {
        this.status = status;
    }
}
